//
// Created by Castle-Moriarty on 2025/11/3.
//
#include <iostream>
using namespace std;

double max(double *numbers,size_t count) {
    double maximum{0};

    for (size_t i{0};i < count;++i) {
        if (numbers[i]>maximum) {
            maximum = numbers[i];
        }
    }
    return maximum;
}

int max(int *numbers,size_t count) {
    int maximum{0};
    for (size_t i{0};i < count;++i) {
        if (numbers[i]>maximum) {
            maximum = numbers[i];
        }
    }
    return maximum;
}

int main() {
    double doubles[]{10.1,11.1,12.3,34.33};
    int ints[]{1,2,3,3,34,5,6};

    auto doubleResult = max(doubles,size(doubles));
    auto intResult = max(ints,size(ints));

    cout << doubleResult << endl;
    cout << intResult << endl;

    return 0;
}